#include "saveslot.h"

void saveSlot::init(startSlot * outside)
{
    startfunc = outside;
}
void saveSlot::slot_save(){
    //第一步：设置保存
    QDir full_relativepath;
    full_relativepath.mkpath(relative_path+time);
    QFile setting;
    setting.setFileName(relative_path+time+tofile);
    setting.open(QIODevice::WriteOnly | QIODevice::Text);
    QTextStream out_setting;
    out_setting.setDevice(&setting);
    qDebug()<< relative_path+time;
    qDebug()<< relative_path+time+tofile;
    for (const QString& arg : startfunc->qarguments) {
        if(!startfunc->qarguments.isEmpty())
            out_setting << arg << ",";//在成像端自行解析参数
    }
    setting.close();
    //第二步：数据保存

}
